package com.codingman.springbootdemo4;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/*
 * @Service：它也用于类级别。它告诉 Spring 该类包含业务逻辑。
 */
@Service
public class BooksService {
	
	@Autowired
	BooksRepository repo;
	
	public void getAllBooks() {
		repo.getAllBooks();
	}

}
